/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package br.com.foxline.clinicplus.entity;

import br.com.foxline.clinicplus.enums.Priority;
import br.com.foxline.clinicplus.enums.SituationAppraisal;
import java.io.Serializable;
import java.util.Date;
import java.util.List;
import javax.persistence.*;

/**
 *
 * @author roniere
 */
@Entity
public class Appraisal implements Serializable {

    @Id
    @SequenceGenerator(sequenceName = "seq_appraisal", name = "seq_appraisal", allocationSize = 1)
    @GeneratedValue(generator = "seq_appraisal", strategy = GenerationType.SEQUENCE)
    private Long id;
    @Lob
    private String text;
    @Lob
    private String textEdit;
    @ManyToOne
    private Customer customer;
    @ManyToOne
    private Diary diary;
    @ManyToOne
    private TemplateAppraisal templateAppraisal;
    @OneToMany
    private List<Item> itens;
    //Usuário q entregou
    @ManyToOne
    private SystemUser systemUserAppraisal;
    //Usuário q editou
    @ManyToOne
    private SystemUser systemUserAppraisalEdit;
    //Usuário q  criou
    @ManyToOne
    private SystemUser systemUser;
    private String recipientName;
    private String recipientDoc;
    @Temporal(javax.persistence.TemporalType.TIMESTAMP)
    private Date creatAt;
    @Temporal(javax.persistence.TemporalType.TIMESTAMP)
    private Date updateAt;
    @Temporal(javax.persistence.TemporalType.TIMESTAMP)
    private Date dateDelivery;
    @Enumerated(EnumType.STRING)
    private SituationAppraisal situationAppraisal;
    @Enumerated(EnumType.STRING)
    private Priority priority;
    @Lob
    private String obs;
    @ManyToOne
    private Doctor doctor;
    @ManyToOne
    private Doctor doctorResponse;
    @Temporal(javax.persistence.TemporalType.TIMESTAMP)
    private Date dateDoctorApproved;
    @Lob
    private String obsDoctor;
    
    private String title;

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }
    
    

    public Doctor getDoctorResponse() {
        return doctorResponse;
    }

    public void setDoctorResponse(Doctor doctorResponse) {
        this.doctorResponse = doctorResponse;
    }

    
    public String getObsDoctor() {
        return obsDoctor;
    }

    public void setObsDoctor(String obsDoctor) {
        this.obsDoctor = obsDoctor;
    }

    public Date getDateDoctorApproved() {
        return dateDoctorApproved;
    }

    public void setDateDoctorApproved(Date dateDoctorApproved) {
        this.dateDoctorApproved = dateDoctorApproved;
    }

    public Doctor getDoctor() {
        return doctor;
    }

    public void setDoctor(Doctor doctor) {
        this.doctor = doctor;
    }
    
    
    public String getObs() {
        return obs;
    }

    public void setObs(String obs) {
        this.obs = obs;
    }

    public SystemUser getSystemUserAppraisalEdit() {
        return systemUserAppraisalEdit;
    }

    public void setSystemUserAppraisalEdit(SystemUser systemUserAppraisalEdit) {
        this.systemUserAppraisalEdit = systemUserAppraisalEdit;
    }

    public Date getUpdateAt() {
        return updateAt;
    }

    public void setUpdateAt(Date updateAt) {
        this.updateAt = updateAt;
    }

    public Date getCreatAt() {
        return creatAt;
    }

    public void setCreatAt(Date creatAt) {
        this.creatAt = creatAt;
    }

    public Customer getCustomer() {
        return customer;
    }

    public void setCustomer(Customer customer) {
        this.customer = customer;
    }

    public Date getDateDelivery() {
        return dateDelivery;
    }

    public void setDateDelivery(Date dateDelivery) {
        this.dateDelivery = dateDelivery;
    }

    public Diary getDiary() {
        return diary;
    }

    public void setDiary(Diary diary) {
        this.diary = diary;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public List<Item> getItens() {
        return itens;
    }

    public void setItens(List<Item> itens) {
        this.itens = itens;
    }

    public Priority getPriority() {
        return priority;
    }

    public void setPriority(Priority priority) {
        this.priority = priority;
    }

    public String getRecipientDoc() {
        return recipientDoc;
    }

    public void setRecipientDoc(String recipientDoc) {
        this.recipientDoc = recipientDoc;
    }

    public String getRecipientName() {
        return recipientName;
    }

    public void setRecipientName(String recipientName) {
        this.recipientName = recipientName;
    }

    public SituationAppraisal getSituationAppraisal() {
        return situationAppraisal;
    }

    public void setSituationAppraisal(SituationAppraisal situationAppraisal) {
        this.situationAppraisal = situationAppraisal;
    }

    public SystemUser getSystemUser() {
        return systemUser;
    }

    public void setSystemUser(SystemUser systemUser) {
        this.systemUser = systemUser;
    }

    public SystemUser getSystemUserAppraisal() {
        return systemUserAppraisal;
    }

    public void setSystemUserAppraisal(SystemUser systemUserAppraisal) {
        this.systemUserAppraisal = systemUserAppraisal;
    }

    public TemplateAppraisal getTemplateAppraisal() {
        return templateAppraisal;
    }

    public void setTemplateAppraisal(TemplateAppraisal templateAppraisal) {
        this.templateAppraisal = templateAppraisal;
    }

    public String getText() {
        return text;
    }

    public void setText(String text) {
        this.text = text;
    }

    public String getTextEdit() {
        return textEdit;
    }

    public void setTextEdit(String textEdit) {
        this.textEdit = textEdit;
    }
}
